// 用户类型
export interface User {
  id: number
  username: string
  email: string
  is_staff: boolean
  is_superuser: boolean
}

// 登录请求
export interface LoginRequest {
  username: string
  password: string
}

// 登录响应
export interface LoginResponse {
  access: string
  refresh: string
}

// API 响应
export interface ApiResponse<T = any> {
  count?: number
  next?: string | null
  previous?: string | null
  results?: T[]
  data?: T
}

// 产品类型
export interface Product {
  id: number
  name: string
  slug: string
  description: string
  price: string
  stock: number
  is_active: boolean
  created_at: string
  updated_at: string
  categories: Category[]
  images: ProductImage[]
}

// 分类类型
export interface Category {
  id: number
  name: string
  slug: string
  description: string
  icon: string
  is_active: boolean
  sort_order: number
}

// 产品图片类型
export interface ProductImage {
  id: number
  image: string
  alt_text: string
  sort_order: number
}

// 轮播图类型
export interface Carousel {
  id: number
  title: string
  image: string
  link: string
  is_active: boolean
  sort_order: number
}

// 分页参数
export interface PaginationParams {
  page?: number
  page_size?: number
}

// 过滤参数
export interface FilterParams {
  search?: string
  is_active?: boolean
  ordering?: string
}

